DEW.appRouter = Backbone.Router.extend({
    routes: {
        "home" : "displayHome",
        "login" : "displayLogin",
        "register" : "displayRegister",
        "finder" : "displayFinder",
        "details/:id" : "displayDetails",
        "*actions" : "defaultRoute"
    },

    initialize: function(){
    
    

    },
     displayHome: function() {
        var homeController = new DEW.HomeController();
        homeController.render();
    },

    
     displayLogin: function() {
        var loginController = new DEW.LoginController();
        loginController.render();
    },
     displayRegister: function() {
        var registerController = new DEW.RegisterController();
        registerController.render();
    },
    displayFinder: function() {
        var finderController = new DEW.FinderController();
        finderController.render();
    },
    

    displayDetails: function(id) {
        DEW.itemID = id;
        var detailsController = new DEW.DetailsController();
        detailsController.render();
    },
    

    defaultRoute: function() {
        this.displayHome();
    }
});